package cn.roadtrip.utilmodule.util.enumpck;


/**
 * 游客创建得行程调度状态
 */
public enum Enum_MainTourTravelLineDispatchStats {
    /**
     * 调度状态。：；：；，
     */
    Audit("Audit", "待调度"),
    Finished("Finished", "调度完成"),
    Cancel("Cancel", "取消")
    ;

    private String s;
    private String title;

    Enum_MainTourTravelLineDispatchStats(String s, String title) {
        this.s = s;
        this.title = title;
    }

    Enum_MainTourTravelLineDispatchStats(String s) {
        this.s = s;
        this.title = Enum_HotelRoomType.parseCode(s).getTitle();
    }

    public String getTitle() {
        return this.title;
    }

    public String getCode() {
        return this.s;
    }

    public static final Enum_MainTourTravelLineDispatchStats parseCode(String code) {
        switch (code) {
            case "Audit":
                return Audit;
            case "Finished":
                return Finished;
            case "Cancel":
                return Cancel;
        }
        return null;
    }

    @Override
    public String toString() {
        return "(code:%s, title:%s)".formatted(this.s, this.title);
    }
}
